unclickable button

104

/*works on all html elements*/
a {
  display: inline-block;
  pointer-events: none;
}
<a href="http://stackoverflow.com" onclick="alert('clicked on link')"></a>
/*pointer events may target its descendant elements
if those descendants have pointer-events set to some other value.*/
/*demo https://codepen.io/abdelghanymh/pen/eYGeMdR*/

Comments

Submit
0 Comments